package com.ljkj.cordial.chat.bean;

import com.ljkj.cordial.chat.R;
import com.ljkj.cordial.chat.base.ChatApp;

public class FontSize {
    public final static float FONT_MIN = 0.85f;
    public final static float FONT_NORMAL = 1.0f;
    public final static float FONT_MAX = 1.15f;
    public final static float FONT_OVER_MAX = 1.3f;
    public final static float FONT_OVER_MAX2 = 1.5f;

    public static String getFontSizeText(int position) {
        String[] str = ChatApp.getInstance().getResources().getStringArray(R.array.array_font_size);

        return str[position];
    }

    public static int getFontSizePosition(float fontSize) {
//        if (fontSize == FONT_NORMAL) {
//            return 0;
//        } else
            if (fontSize == FONT_MAX) {
            return 0;
        } else if (fontSize == FONT_OVER_MAX) {
            return 1;
        } else if (fontSize == FONT_OVER_MAX2) {
            return 2;
        }

        return 0;
    }
}
